package io.awen.modules.sign.service;


import com.baomidou.mybatisplus.extension.service.IService;
import io.awen.common.utils.PageUtils;
import io.awen.common.utils.R;
import io.awen.modules.sign.entity.SignCarEntity;
import io.awen.modules.sign.entity.SignCarLoadRecordEntity;
import io.awen.modules.sign.entity.SignContainerEntity;
import io.awen.modules.sign.entity.SignSinkEntity;
import io.awen.modules.sign.qo.SignCarLoadRecordQo;
import org.springframework.web.bind.annotation.RequestBody;

import java.util.List;
import java.util.Map;

public interface SignCarLoadRecordService extends IService<SignCarLoadRecordEntity> {

    void insertWhenLoadRecord(SignCarEntity car,Double Speed, String Weight, Double lon, Double lat);

    PageUtils queryPage(SignCarLoadRecordQo qo);
    List<Map<String, Object>> weightTotalGroupByContainer(SignCarLoadRecordQo qo);
    List<Map<String, Object>> weightTotalGroupBySink(SignCarLoadRecordQo qo);
    R submit(SignCarLoadRecordEntity qo);
    SignContainerEntity getContainer(SignCarLoadRecordEntity qo);
    SignSinkEntity getSink(SignCarLoadRecordEntity qo);
    PageUtils queryLedger(SignCarLoadRecordQo qo);
    PageUtils queryLedgerDriver(SignCarLoadRecordQo qo);
    PageUtils totalTable(@RequestBody SignCarLoadRecordQo qo);

    PageUtils queryPageWeightTotalGroupByCar(SignCarLoadRecordQo qo);

    List<Map<String, Object>> weightTotalGroupByCar(SignCarLoadRecordQo qo);
    List<Map<String, Object>> weightTotalGroupByTimeLength(SignCarLoadRecordQo qo);
    List<Map<String, Object>> weightGroupByCarAndTime(SignCarLoadRecordQo qo);
    Double weightTotal(SignCarLoadRecordQo qo);
}
